package com.javaee.thinks.po; // 假设你的实体类放在 com.javaee.thinks.po 包下

import java.sql.Timestamp;

public class ConversationHistory {
    private Integer id;
    private String conversationId;
    private String role;
    private String message;
    private Timestamp timestamp;

    // 构造函数 (可选)
    public ConversationHistory() {}

    public ConversationHistory(String conversationId, String role, String message) {//常用
        this.conversationId = conversationId;
        this.role = role;
        this.message = message;
    }
    public ConversationHistory(Integer id, String conversationId, String role, String message,Timestamp timestamp) {
        this.id = id;
        this.conversationId = conversationId;
        this.role = role;
        this.message = message;
        this.timestamp = timestamp;
    }

    // Getter 和 Setter 方法
    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public String getConversationId() {
        return conversationId;
    }

    public void setConversationId(String conversationId) {
        this.conversationId = conversationId;
    }

    public String getRole() {
        return role;
    }

    public void setRole(String role) {
        this.role = role;
    }

    public String getMessage() {
        return message;
    }

    public void setMessage(String message) {
        this.message = message;
    }

    public Timestamp getTimestamp() {
        return timestamp;
    }

    public void setTimestamp(Timestamp timestamp) {
        this.timestamp = timestamp;
    }

    @Override
    public String toString() {
        return "Conversation{" +
                "id=" + id +
                ", conversationId='" + conversationId + '\'' +
                ", role='" + role + '\'' +
                ", message='" + message + '\'' +
                ", timestamp=" + timestamp +
                '}';
    }
}